import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '../views/HomeView.vue'


const routes = [
  {
    path: '/login',
    name: 'LoginView',
    components:{
      LoginRouterView: () => import('../views/Login.vue'),
    }
  },
  {
    path: '/',
    name: 'HomeView',
    component: HomeView,
  },
  {
    path: '/class-manage',
    name: 'ClassView',
    component: () => import('../views/ClassView.vue'),
  },
  {
    path: '/lang-manage',
    name: 'LangView',
    component: () => import('../views/LangView.vue'),
  },
  {
    path: '/module-manage',
    name: 'ModuleView',
    component: () => import('../views/ModuleView.vue'),
  },
  {
    path: '/student-manage',
    name: 'StudentView',
    component: () => import('../views/StudentView.vue'),
  },
  {
    path: '/enterprise-manage',
    name: 'EnterpriseView',
    component: () => import('../views/EnterpriseView.vue'),
  },
  {
    path: '/role-manage',
    name: 'RoleView',
    component: () => import('../views/RoleView.vue'),
  },
  {
    path: '/task-manage',
    name: 'TaskView',
    component: () => import('../views/TaskView.vue'),
  },
  {
    path: '/menu-manage',
    name: 'MenuView',
    component: () => import('../views/MenuView.vue')
  },
  {
    path: '/func-manage', 
    name: 'FuncView',
    component: () => import('../views/FuncView.vue')
  },
  {
    path: '/permission-manage',
    name: 'PermissionView', 
    component: () => import('../views/PermissionView.vue')
  }
]

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes,
})

export default router
